package com.github.niefy.modules.third.entity;

import com.baomidou.mybatisplus.annotation.*;
import com.github.niefy.common.utils.Json;
import lombok.Builder;
import lombok.Data;

import java.io.Serializable;
import java.time.LocalDateTime;

/**
 * 批量拉取模板消息记录
 */
@Data
@Builder
@TableName("third_template_msg_task_log")
public class ThirdTemplateMsgTaskLog implements Serializable {

    private static final long serialVersionUID = 1L;

    @TableId(type = IdType.AUTO)
    private Long logId;

    /**
     * 消息推送顺序号起，包含
     */
    @TableField(insertStrategy = FieldStrategy.NOT_EMPTY)
    private Long msgPushSeqIdFrom;

    /**
     * 消息推送顺序号到，包含
     */
    @TableField(insertStrategy = FieldStrategy.NOT_EMPTY)
    private Long msgPushSeqIdTo;

    /**
     * 拉取时间
     */
    @TableField(insertStrategy = FieldStrategy.NOT_EMPTY)
    private LocalDateTime pullTime;


    @Override
    public String toString() {
        return Json.toJsonString(this);
    }
}
